package com.ywq.app.domain;

import java.io.Serializable;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.List;

import com.ywq.common.util.Common;
public class ArtActivity implements Serializable{
	
	private static final long serialVersionUID = -4316180995919582463L;
	private String identifier;
	private String member;
	private String endDate;
	private String startDate;
	private String startTime;
	private String endTime;
	private String cover;
	private String description;
	private String title;
	private String subtitle;
	private Date gmtCreated;
	private Date gmtModified;
	private Boolean isShow;
	private Date sDate;
	private Date eDate;
	private Date sTime;
	private Date eTime;
	private String address;
	private String titlePic;
	
	private String titlePic1;
	private String titlePic2;
	private String titlePic3;
	private String activityType;
	private Integer personNum;
	private Integer signNum;
	/*private List<ArtRoomPic> artPicList;*/
	

	public Boolean getOverTime() throws ParseException{
		if(!Common.empty(endDate) && ! !Common.empty(endTime)){
			String overTime =endDate+""+endTime;
			SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
			Date overDate = sdf.parse(overTime);
			Date nowDate = Calendar.getInstance().getTime();
			Boolean over =nowDate.before(overDate);
			return over;
		}
		return null;
	}
	
	public Integer getPersonNum() {
		return personNum;
	}
	public void setPersonNum(Integer personNum) {
		this.personNum = personNum;
	}
	public Integer getSignNum() {
		return signNum;
	}
	public void setSignNum(Integer signNum) {
		this.signNum = signNum;
	}
	public String getActivityType() {
		return activityType;
	}
	public void setActivityType(String activityType) {
		this.activityType = activityType;
	}
	public String getTitlePic1() {
		return titlePic1;
	}
	public void setTitlePic1(String titlePic1) {
		this.titlePic1 = titlePic1;
	}
	public String getTitlePic2() {
		return titlePic2;
	}
	public void setTitlePic2(String titlePic2) {
		this.titlePic2 = titlePic2;
	}
	public String getTitlePic3() {
		return titlePic3;
	}
	public void setTitlePic3(String titlePic3) {
		this.titlePic3 = titlePic3;
	}
	
	public String getTitlePic() {
		return titlePic;
	}
	public void setTitlePic(String titlePic) {
		this.titlePic = titlePic;
	}
	public String getAddress() {
		return address;
	}
	public void setAddress(String address) {
		this.address = address;
	}
	public Date getsTime() {
		return sTime;
	}
	public void setsTime(Date sTime) {
		this.sTime = sTime;
	}
	public Date geteTime() {
		return eTime;
	}
	public void seteTime(Date eTime) {
		this.eTime = eTime;
	}
	public Date getsDate() {
		return sDate;
	}
	public void setsDate(Date sDate) {
		this.sDate = sDate;
	}
	public Date geteDate() {
		return eDate;
	}
	public void seteDate(Date eDate) {
		this.eDate = eDate;
	}
	public Boolean getIsShow() {
		return isShow;
	}
	public void setIsShow(Boolean isShow) {
		this.isShow = isShow;
	}
	public String getIdentifier() {
		return identifier;
	}
	public void setIdentifier(String identifier) {
		this.identifier = identifier;
	}
	public String getMember() {
		return member;
	}
	public void setMember(String member) {
		this.member = member;
	}
	public String getEndDate() {
		return endDate;
	}
	public void setEndDate(String endDate) {
		this.endDate = endDate;
	}
	public String getStartDate() {
		return startDate;
	}
	public void setStartDate(String startDate) {
		this.startDate = startDate;
	}
	public String getStartTime() {
		return startTime;
	}
	public void setStartTime(String startTime) {
		this.startTime = startTime;
	}
	public String getEndTime() {
		return endTime;
	}
	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}
	public String getCover() {
		return cover;
	}
	public void setCover(String cover) {
		this.cover = cover;
	}
	public String getDescription() {
		return description;
	}
	public void setDescription(String description) {
		this.description = description;
	}
	public String getTitle() {
		return title;
	}
	public void setTitle(String title) {
		this.title = title;
	}
	public String getSubtitle() {
		return subtitle;
	}
	public void setSubtitle(String subtitle) {
		this.subtitle = subtitle;
	}
	public Date getGmtCreated() {
		return gmtCreated;
	}
	public void setGmtCreated(Date gmtCreated) {
		this.gmtCreated = gmtCreated;
	}
	public Date getGmtModified() {
		return gmtModified;
	}
	public void setGmtModified(Date gmtModified) {
		this.gmtModified = gmtModified;
	}
	public Boolean getIsOver() throws ParseException {
		
		Date now =Calendar.getInstance().getTime();
		SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
		Date dateS = sdf.parse(startDate);
		Date dateE = sdf.parse(endDate);
		boolean isOver =false;
		if(now.before(dateE) && now.after(dateS)){
			isOver=true;
		}
		return isOver;
	}
}
